import qs from 'qs'
export default {
    name: "Devicedetail",
    components: {},
    data() {
        return {
            rowId: this.$route.params.rowId,
            //row: this.$route.params.row,
            keyName: "",
            Valuename: "",
            list: {},
            arr: [],
        };
    },
    computed: {

    },
    watch: {},
    created() {
        this.initDeviceDetail();
        console.log(this.rowId);
        //console.log("对象", this.row);
    },
    mounted() { },
    methods: {
        initDeviceDetail() {
            var postData = {
                rowKey: this.rowId,
            }
            this.$http.post('/deviceCommonInfoController/queryDeviceInfo', qs.stringify(postData))
                .then((res) => {
                    if (res.status = 200) {
                      if(res.data == null){
                         this.$message.error("暂无数据进行显示");
                         return false;
                      } else {
                        this.list = res.data;
                      }
                    }
                }).catch((err) => {
                console.log(err);
           });
        }
    }
};